package StringDemo.TraverceString;
import java.util.Scanner;

public class Traverce {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        System.out.print("请输入一个字符串");
        String st = sc.nextLine();
        //length用于查找字符串的长度
        for (int i = 0; i < st.length(); i++) {
            //charAt用于查找字符串中index下标的字符
            System.out.print(st.charAt(i));
        }
    }
}
